package com.micai.springboot.service;

import com.micai.springboot.entity.BookEntity;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.PageRequest;

import java.util.List;

/**
 * 描述：
 * <p>
 * Author: 赵新国
 * Date: 2018/1/23 16:32
 */
public interface BookService {

    BookEntity save(BookEntity book);

    void delete(BookEntity book);

    BookEntity findOne(String id);

    Iterable<BookEntity> findAll();

    Page<BookEntity> findByAuthor(String author, PageRequest pageRequest);

    List<BookEntity> findByTitle(String title);
}
